﻿using project.B12.ViewModels;
using System;
using System.Collections.Generic;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Shapes;

namespace project.B12.Views
{
    /// <summary>
    /// AnalyseView.xaml 的交互逻辑
    /// </summary>
    public partial class MonitorView : UserControl
    {
        public MonitorView()
        {
            InitializeComponent();
        }

        private void LeftSampleType_TextChanged(object sender, TextChangedEventArgs e)
        {
            LeftSampleType.IsDropDownOpen = true;
        }

        private void RightSampleType_TextChanged(object sender, TextChangedEventArgs e)
        {
            RightSampleType.IsDropDownOpen = true;
        }

        private void leftSkipSample_Checked(object sender, RoutedEventArgs e)
        {
            if (leftSkipSample.IsChecked == true)
                leftSampleContinuation.IsChecked = false;
            else if (leftSkipSample.IsChecked == false)
                leftSampleContinuation.IsChecked = true;
        }

        private void leftSampleContinuation_Checked(object sender, RoutedEventArgs e)
        {
            if (leftSampleContinuation.IsChecked == true)
                leftSkipSample.IsChecked = false;
            else if (leftSampleContinuation.IsChecked == false)
                leftSkipSample.IsChecked = true;
        }

        private void rightSampleContinuation_Checked(object sender, RoutedEventArgs e)
        {
            if (rightSampleContinuation.IsChecked == true)
                rightSkipSample.IsChecked = false;
            else if (leftSampleContinuation.IsChecked == false)
                rightSampleContinuation.IsChecked = true;
        }

        private void rightSkipSample_Checked(object sender, RoutedEventArgs e)
        {
            if (rightSkipSample.IsChecked == true)
                rightSampleContinuation.IsChecked = false;
            else if (rightSkipSample.IsChecked == false)
                rightSampleContinuation.IsChecked = true;
        }
    }
}
